/**
 * 
 */
package uicgas.register.GUI;

import uicgas.globaldata.CreditCard;
import uicgas.globaldata.Pump;
import uicgas.globaldata.States;
import uicgas.globaldata.Transaction;
import uicgas.register.RegisterLogic;
import uicgas.register.remotecmds.NotifyAssistance;

/**
 * @author Steve
 *
 */
public class RunRegister
{
	PumpSelectionScreen pumpSelectionScreen;
	RegisterLogic registerSystem = new RegisterLogic();
	MainRegister mainRegisterScreen = new MainRegister(registerSystem);

	/**
	 * 
	 */
	public RunRegister()
	{
		// TODO Auto-generated constructor stub
	}
	
	public boolean Run()
	{
		CreditCard Card = new CreditCard("Halm", "0000000000000000000", null);
		Transaction newTransaction = new Transaction(9.20, 2.345, Card);
		final Pump pumptemp = new Pump(3, newTransaction, 11.00, States.DEACTIVATED);
		pumptemp.setPumpNum(3);
		registerSystem.allPumps[0] = pumptemp;
		//this.pumpSelectionScreen = new PumpSelectionScreen(registerSystem.allPumps[9], registerSystem);
		this.mainRegisterScreen.setVisible(true);
		registerSystem.MainScreen = mainRegisterScreen;
		//registerSystem.startComm();
		for(int i=0; i<1000000; i++)
		{
			
		}
		NotifyAssistance myAssistance = new NotifyAssistance(registerSystem, registerSystem.getCommunication());
		myAssistance.executeRemoteCommand();
		return true;
		
	}

	/**
	 * @param args
	 */
	public static void main(String[] args)
	{
		RunRegister myregister = new RunRegister();
		myregister.Run();
		// TODO Auto-generated method stub

	}

}
